package credential

import (
	"github.com/aliyun/credentials-go/credentials"
)

func CreateCredentials(accessKeyid, accessKeySecret string) (credential credentials.Credential, err error) {
	AKconfig := new(credentials.Config).SetType("access_key").SetAccessKeyId(accessKeyid).SetAccessKeySecret(accessKeySecret)
	akCredential, err := credentials.NewCredential(AKconfig)
	if err != nil {
		return nil, err
	}
	return akCredential, nil
}
